package com.ys.shiro;

import org.apache.shiro.authc.UsernamePasswordToken;

/**
 * @ClassName CustomUsernamePasswordToken自定义扩展用户密码token
 * @Description TODO
 * @Author alula
 * @Date 2021-10-13 10:59
 */
public class CustomUsernamePasswordToken extends UsernamePasswordToken {
    private  boolean freePwd = false;//免密标识，默认为false，不免密，为true时将用数据库加密密码进行验证，passwordservice密码验证不加密


    public CustomUsernamePasswordToken(String username, String password, boolean rememberMe, String host, boolean freePwd) {
        super(username, password, rememberMe, host);
        this.freePwd = freePwd;
    }

    public boolean getFreePwd() {
        return freePwd;
    }

    public void setFreePwd(boolean freePwd) {
        this.freePwd = freePwd;
    }
}
